//
//  DemoViewController.m
//  test
//
//  Created by mPaaS on 16/11/21.
//  Copyright © 2016年 Alibaba. All rights reserved.
//

#import "DemoViewController.h"
#import <APRemoteLogging/APRemoteLogging.h>
//获取设备标识
#import <UTDID/UTDevice.h>

//扫码
//#import "ScanTestViewController.h"
//
//#import "SaveDataViewController.h"
//
//#import "LocationViewController.h"

@interface DemoViewController ()

@end

@implementation DemoViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
   NSString *utdid =  [UTDevice utdid];// Wslm//aMKOEDAAhBwnrD2vw7
    //应用删除后，也是不变的
    //调用日志
    UIButton *btn = [UIButton buttonWithType:UIButtonTypeCustom];
    
    btn.frame = CGRectMake(10, 70, 100, 60);
    btn.backgroundColor = [UIColor greenColor];
    [btn setTitle:@"点我扫码" forState:UIControlStateNormal];
    [btn addTarget:self action:@selector(scanAction:) forControlEvents:UIControlEventTouchUpInside];
    [self.view addSubview:btn];
    
    
    UIBarButtonItem *leftitem = [[UIBarButtonItem alloc] initWithTitle:@"存储" style:UIBarButtonItemStylePlain target:self action:@selector(saveAction:)];
    self.navigationItem.leftBarButtonItem = leftitem;
    
    UIBarButtonItem *rightItem = [[UIBarButtonItem alloc] initWithTitle:@"定位" style:UIBarButtonItemStylePlain target:self action:@selector(locationAction)];
    self.navigationItem.rightBarButtonItem = rightItem;
    
    
}
- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

- (void)locationAction{
//    [self.navigationController pushViewController:[[LocationViewController alloc] init] animated:YES];
}

- (void)saveAction:(UIButton *)btn{
   
//    [self.navigationController pushViewController:[[SaveDataViewController alloc] init] animated:YES];
}

- (void)scanAction:(UIButton *)btn{
   
//    [self.navigationController pushViewController:[[ScanTestViewController alloc] init] animated:YES];
    
}
@end
